<?php
	include("includes/secure.php");
	$cadena = explode("/",$_GET["f"]);
	if( in_array("file_upload",$cadena) && in_array("email_attachment",$cadena) ){
		$f = $_GET["f"];
		header("Content-type: application/octet-stream");
		header("Content-Disposition: attachment; filename=\"$f\"\n");
		$fp=fopen("$f", "r");
		fpassthru($fp);
	}else{
		echo "<script>window.location.href='logout.php'</script>";
	}	
?>
